package edu.dayu.proxyTest3;

import edu.dayu.proxyTest2.Invocation;

public class LogInterceptor implements Interceptor{
    @Override
    public Object intercept(Invocation invocation) throws Exception {
        System.out.println("log 日志");
        Object process = invocation.process();
        System.out.println("log 之前方法之后");
        return process;
    }

    @Override
    public Object plugin(Object target) {
        return HWInvocationHandler.wrap(target,this);
    }
}
